import request from '@/utils/request'

export function login(data) {
  return request({
    url: '/userInfo/login',
    method: 'post',
    data
  })
}

export function getInfo() {
  return request({
    url: '/userInfo/queryOne',
    method: 'get',
  })
}
export function getDefaultUser() {
  return request({
    url: '/userInfo/queryDefault',
    method: 'get',
  })
}

export function logout() {
  return request({
    url: '/userInfo/logout',
    method: 'post'
  })
}
// 修改密码
export function updatePassword(data) {
  return request({
    url: '/userInfo/updatePassword',
    method: 'put',
    data
  })
}


